<?php
if (!defined('_PS_VERSION_'))
  exit;
 
class ActuAccueil extends Module
  {
  public function __construct()
    {
    $this->name = 'actuaccueil';
    $this->tab = 'Actu accueil';
    $this->version = 1.0;
    $this->author = 'Nicolas Gbenou';
    $this->need_instance = 0;
 
    parent::__construct();
 
    $this->displayName = $this->l('Accueil');
    $this->description = $this->l('Gére les 3 actus de l accueil');
    }
 
  public function install()
    {
    if (parent::install() == false OR !$this->registerHook('home'))
    return false;
  return true;
    }
  public function hookHome($params)
	  {

	  require_once(dirname(__FILE__).'/../../classes/Accueil.php');
	  
	  global $smarty;
	  $tab_actus = Accueil::getBlocsAccueil();
	  $smarty->assign('tab_actus', $tab_actus ); 
	  return $this->display(__FILE__, 'accueil.tpl');
	  print_r($tab_actus);
	   
	  }
 
  }
?>
